package com.example.steamricerake;

import com.example.steamricerake.R;
import android.app.Activity;
import android.content.Intent;
import android.net.Uri;
import android.os.Bundle;
import android.view.Menu;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
import android.widget.MediaController;
import android.widget.VideoView;

public class d extends Activity {
	private VideoView mv;
	private Button fanhui;
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		// TODO Auto-generated method stub
		super.onCreate(savedInstanceState);
		setContentView(R.layout.d);
		mv=(VideoView)findViewById(R.id.mv);
		fanhui=(Button)findViewById(R.id.fanhui);
		mv.setVideoURI(Uri.parse("android.resource://com.example.steamricerake/"+R.raw.view));
		mv.setMediaController(new MediaController(this));
		mv.requestFocus();
		 fanhui.setOnClickListener(new OnClickListener() {
				
				@Override
				public void onClick(View arg0) {
					// TODO Auto-generated method stub
					 Intent intent = new Intent();
		                intent.setClass(d.this, MainActivity.class);
		                startActivity(intent);	
				}
			});
	}

	@Override
	public boolean onCreateOptionsMenu(Menu menu) {
		// Inflate the menu; this adds items to the action bar if it is present.
		getMenuInflater().inflate(R.menu.main, menu);
		return true;
	}

}
